package demo.slf4j;

import nsl.utils.UtilFile;
import org.apache.log4j.xml.DOMConfigurator;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

/**
 * Description:
 * Created by t410 on 2017/6/26.
 */
public class Slf4jDemo {
    static{
        String xmlPath="xml/log4j.xml";
        String absPath= UtilFile.getAbsPath(xmlPath);
        DOMConfigurator.configure(absPath);
    }

    private static final Logger logger = LoggerFactory.getLogger(Slf4jDemo.class);

    public static void main(String[] args) {
        logger.debug("Here is some DEBUG");

        logger.info("Here is some INFO");

        logger.warn("Here is some WARN");

        logger.error("Here is some ERROR");



    }
}
